<svg class="container"><rect class="boxes"></rect></svg>

<style>
/* From Uiverse.io by elijahgummer  - Tags: simple, animation, green, loader, smooth, modern, animated, css */
.container {
  width: 50px;
  height: 50px;
}

.container .boxes {
  width: 50px;
  height: 50px;
  fill: none;
  stroke-width: 50px;
  stroke: #43cb85;
  stroke-dasharray: 50;
  stroke-dashoffset: 50%;
  animation: animate 2s linear infinite;
}

@keyframes animate {
  to {
    stroke-dashoffset: 250%;
  }
}

</style>
    